#ifndef MATRIXKEYS_CONTROL_H
#define MATRIXKEYS_CONTROL_H

#include "hal_MatrixKeys.h"


/**
 * 用户需要自己打开按键和抬起开关 1是打开 0是关闭
 * 打开指定功能后，需要自己在合适的位置定义相关功能函数，可以空实现
 * 例：按下为1 则实现void Key_Is_Pressed(u8 row, u8 column);函数
 */
#define KeyPressed_Switch 1 //按键按下功能开关
#define KeyRaiised_Swtich 0 

//按键抬起功能开关
extern void Key_Is_Pressed(char row, char column);
extern void Key_Is_Raised(char row, char column);

void MatrixKeys_Init();

char MatrixKeys_IsState(char row, char col, char state);

unsigned int MatrixKey_Scan();

void EEPROM_Write(unsigned int EE_address, unsigned char * DataAddress, unsigned int number);

void EEPROM_Read(unsigned int EE_address, unsigned char * DataAddress, unsigned int number);

void EEPROM_Erase(unsigned int EE_address);




#endif // MATRIXKEYS_CONTROL_H

